home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1995 October / EnigmA AMIGA RUN 01 (1995)(G.R. Edizioni)(IT)[!][issue 1995-10][Aminet 7].iso / Aminet / util / wb / DosMan121.lha / man / Get < prev    next >
Text File  |  1995-05-05  |  3KB  |  71 lines

  1.     GET (2.x/3.x Only) (Internal Command)
  2.  
  3.     
  4.     NAME
  5.             GET - Shows the contents of a local environment 
  6.         variable.
  7.  
  8.     SYNOPSIS
  9.             GET varname
  10.         
  11.     DESCRIPTION
  12.             A named text string that is stored in an environment 
  13.         space is a local environment variable. It can only be 
  14.         accessed through the shell it was created in or from a 
  15.         shell that was spawned from the shell it was created in.
  16.  
  17.             OK... so what's the difference between GET and 
  18.         SETENV. Well, SETENV is stored in the RAM disk and is 
  19.         global to all system functions. GET resides in some 
  20.         private (reserved) memory that may only be accessed as 
  21.         described above.
  22.  
  23.             By placing a dollar sign before the name, you can 
  24.         swap the value of a local environment variable on the 
  25.         command line. In other words, if you type 'ECHO $Peter' 
  26.         you are creating the same local environment variable as 
  27.         GET Peter.
  28.  
  29.     
  30.     KEYWORDS
  31.         varname  
  32.             This is the name of the environment variable to get. 
  33.  
  34.             There are many local environment variables which are 
  35.         already created by the 2.x/3.x operating systems. The 
  36.         proper use of these makes AmigaDOS a very flexible and 
  37.         powerful scripting language. The more important and 
  38.         useful of these variables are:
  39.  
  40.         Process
  41.             The process number of the current Shell
  42.  
  43.             Echo
  44.             Decides whether or not the Shell will repeat each of 
  45.         the commands as they are executed. If 'SET Echo on', then 
  46.         the commands are repeated and displayed.  Anyother use of 
  47.         Echo will not allow any commands to be repeated. Turning 
  48.         Echo on helps you to debug any scripts that you are 
  49.         having problems with, since there is no other way to tell 
  50.         how they failed. With Echo on, you can tell which line in 
  51.         the script failed to work.
  52.  
  53.         RC
  54.             The return code of the last command that was 
  55.         executed. You can manipulate this return code instead of 
  56.         using IF WARN or IF FAIL commands structures. This is a 
  57.         more efficient programming algorythm routine.
  58.  
  59.         Result2
  60.             The error number of why the last command failed. You 
  61.         can use the FAULT and/or WHY commands to try to figure 
  62.         out the exact nature of the error.
  63.  
  64.  
  65.     EXAMPLES
  66.  
  67.             1. To print the contents of an environment variable 
  68.         named StupidMahedi:
  69.  
  70.              GET StupidMahedi
  71.